package com.lq.ecoldchain.ui.withdraw.mycard

import android.view.View
import com.alibaba.android.arouter.facade.annotation.Route
import com.alibaba.android.arouter.launcher.ARouter
import com.lq.ecoldchain.R
import com.lq.ecoldchain.base.BaseNavigator
import com.lq.ecoldchain.base.view.BaseActivity
import com.lq.ecoldchain.callback.SafeClickListener
import com.lq.ecoldchain.databinding.ActivityMyCardBinding
import org.kodein.di.Kodein
import org.kodein.di.generic.instance

/*
*2019/1/7 0007  16:40
*function by lq
*/
@Route(path = BaseNavigator.myCard)
class MyCardListActivity:BaseActivity<ActivityMyCardBinding>(){
    override val layoutId = R.layout.activity_my_card
    override val viewDelegate: MyCardDelegate by instance()

    override fun initView() {
        binding.delegate = viewDelegate
        titleText("我的银行卡")
        rightIcon(R.drawable.add_icon,object:SafeClickListener(){
            override fun onNoDoubleClick(v: View) {
                ARouter.getInstance().build(BaseNavigator.addcard).navigation()
            }
        })
    }

    override val kodein = Kodein.lazy {
        extend(parentKodein)
        import(mycardKodeinModule)
    }

}